<template>
  <a-modal
    title="保存模型" 
    :visible="dialogVisible" 
    @cancel="dialogVisible = false"
    :confirmLoading="confirmLoading"
    :destroyOnClose='true'
    :title="`保存模型`"
    cancelText="取消"
    okText="提交"
    :okButtonProps="{
      props:{
        ghost:true,
        icon:'save',
      },
      on:{click:()=>{$emit('MODEL_SAVE')}}
    }"
    >
    <div class="modal-body-div">
      <span class="ant-form-item-required">模型名称:</span>
      <a-input v-model="modelInfo.name" placeholder="给模型起个名字吧"/>
    </div>
    <div class="modal-body-div">
      <span class="ant-form-item-required">模型描述:</span>
      <a-input v-model="modelInfo.description" placeholder="模型描述信息"/>
    </div>
    <div class="modal-body-div">
      <span class="ant-form-item-required">创建时间:</span>
      <a-input v-model="modelInfo.createTime" disabled/>
    </div>
    <div class="modal-body-div">
      <span class="ant-form-item-required">最近保存:</span>
      <a-input v-model="modelInfo.saveTime" disabled/>
    </div>
  </a-modal>
</template>
<script>
  export default {
    data() {
      return {
        dialogVisible: false,
        confirmLoading: false,
      }
    },
    props:['modelInfo'],
    methods: {
      init() {
        this.dialogVisible = true
      }
    }
  }
</script>
